package pCloud.message;

import java.io.Serializable;

public class PolicyManagementReply implements Serializable{
	public static final int SUCCESS = 1;
	public static final int FAIL = 0;

	public static final String ADDED = "added";
	public static final String REMOVED = "removed";	
	
	String type;
	int status;

	public int getStatus() {
		return status;
	}

	public int getPolicyIndex() {
		return policyIndex;
	}

	int policyIndex;

	public PolicyManagementReply(int status, int index, String type) {
		this.status = status;
		this.policyIndex = index;
		this.type = type;
	}

	public String toString() {
		String s;
		if (status==SUCCESS)
			s="SUCCESS";
		else
			s="FAIL";
		return "Policy file " + policyIndex + " was " + type + ". Status = "
				+ s;
	}
}
